﻿using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;

public partial class smpic : System.Web.UI.Page
{
    News n = new News();
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!this.IsPostBack)
        {
            this.Label1.Text = n.GetContentByCid(328);
            this.Label2.Text = n.GetContentByCid(331);
            this.Label3.Text = n.GetContentByCid(330);
            BindTWAL();
        }
    }

    public void BindTWAL()
    {
        DataTable dt = new DataTable();
        SqlHelper.FillDataTable("select top 8 * from news where classid=329 order by id desc",dt);
        this.DataList1.DataSource = dt;
        this.DataList1.DataBind();
    }
}
